# from website.models import Video #需要建立api的文章模型数据
# from rest_framework import serializers #系列化器
# from rest_framework.response import Response #构建视图，返回JSON
# from rest_framework.decorators import api_view

# @api_view(['GET', 'POST'])  #装饰器
# def video(request):
#     video_list = Video.objects.order_by('-id')
#     if request.method == 'GET':
#         serializer = VideoSerializer(video_list, many=True)
#         return Response(serializer.data)

